﻿using System;
using System.Collections.Generic;
using TaleWorlds.Library;
using TaleWorlds.Localization;

namespace TaleWorlds.Core
{
	// Token: 0x02000020 RID: 32
	public class CharacterAttribute : PropertyObject
	{
		// Token: 0x17000082 RID: 130
		// (get) Token: 0x06000191 RID: 401 RVA: 0x00006B2F File Offset: 0x00004D2F
		public MBReadOnlyList<SkillObject> Skills
		{
			get
			{
				return this._skills;
			}
		}

		// Token: 0x17000083 RID: 131
		// (get) Token: 0x06000192 RID: 402 RVA: 0x00006B37 File Offset: 0x00004D37
		// (set) Token: 0x06000193 RID: 403 RVA: 0x00006B3F File Offset: 0x00004D3F
		public TextObject Abbreviation { get; private set; }

		// Token: 0x06000194 RID: 404 RVA: 0x00006B48 File Offset: 0x00004D48
		public CharacterAttribute(string stringId) : base(stringId)
		{
		}

		// Token: 0x06000195 RID: 405 RVA: 0x00006B51 File Offset: 0x00004D51
		internal void AddSkill(SkillObject skillObject)
		{
			this._skills.Capacity = this._skills.Count + 1;
			this._skills.Add(skillObject);
		}

		// Token: 0x06000196 RID: 406 RVA: 0x00006B77 File Offset: 0x00004D77
		public void Initialize(TextObject name, TextObject description, TextObject abbreviation)
		{
			base.Initialize(name, description);
			this.Abbreviation = abbreviation;
			this._skills = new MBList<SkillObject>(0);
			base.AfterInitialized();
		}

		// Token: 0x06000197 RID: 407 RVA: 0x00006B9A File Offset: 0x00004D9A
		internal static void AutoGeneratedStaticCollectObjectsCharacterAttribute(object o, List<object> collectedObjects)
		{
			((CharacterAttribute)o).AutoGeneratedInstanceCollectObjects(collectedObjects);
		}

		// Token: 0x06000198 RID: 408 RVA: 0x00006BA8 File Offset: 0x00004DA8
		protected override void AutoGeneratedInstanceCollectObjects(List<object> collectedObjects)
		{
			base.AutoGeneratedInstanceCollectObjects(collectedObjects);
		}

		// Token: 0x0400015B RID: 347
		private MBList<SkillObject> _skills;
	}
}
